package com.hgdp.medicalexamination.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.hgdp.medicalexamination.entity.DicFolk;
import com.hgdp.medicalexamination.mapper.DicFolkMapper;
import com.hgdp.medicalexamination.service.DicFolkService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.AllArgsConstructor;

/**
 * @param 
 * @author hgdp
 * @date 2020-07-30 10:36:49
 */

@Service
@AllArgsConstructor
public class DicFolkServiceImpl extends ServiceImpl<DicFolkMapper, DicFolk> implements DicFolkService {
	
	@Override
	public IPage<DicFolk> queryPage(Page page, DicFolk dicFolk) {
		IPage<DicFolk> pages =baseMapper.selectPage(page,Wrappers.query(dicFolk));
		page.setTotal(baseMapper.selectCount(Wrappers.query(dicFolk)));
		return pages;
	}
}